/*
 Navicat Premium Data Transfer

 Source Server         : 华为云
 Source Server Type    : MySQL
 Source Server Version : 80032
 Source Host           : 123.60.140.66:3306
 Source Schema         : yrmall_ums

 Target Server Type    : MySQL
 Target Server Version : 80032
 File Encoding         : 65001

 Date: 03/08/2023 16:30:28
*/

SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;

-- ----------------------------
-- Table structure for ums_growth_change_history
-- ----------------------------
DROP TABLE IF EXISTS `ums_growth_change_history`;
CREATE TABLE `ums_growth_change_history` (
  `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'id',
  `member_id` bigint NOT NULL COMMENT 'member_id',
  `change_count` int NOT NULL COMMENT '改变值',
  `data_source` varchar(255) NOT NULL COMMENT '数据来源',
  `remark` varchar(500) DEFAULT NULL COMMENT '备注',
  `create_time` datetime DEFAULT NULL,
  `create_by` varchar(255) DEFAULT NULL,
  `update_time` datetime DEFAULT NULL,
  `update_by` varbinary(255) DEFAULT NULL,
  `is_deleted` bit(1) NOT NULL DEFAULT b'0',
  `version` int NOT NULL DEFAULT '1',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1686774054983929858 DEFAULT CHARSET=utf8mb3 ROW_FORMAT=DYNAMIC COMMENT='会员成长值变更记录';

-- ----------------------------
-- Records of ums_growth_change_history
-- ----------------------------
BEGIN;
INSERT INTO `ums_growth_change_history` (`id`, `member_id`, `change_count`, `data_source`, `remark`, `create_time`, `create_by`, `update_time`, `update_by`, `is_deleted`, `version`) VALUES (1683848569449345025, 1, 10, '1', '每日签到', '2023-07-25 22:35:58', 'Leron', NULL, NULL, b'0', 1);
INSERT INTO `ums_growth_change_history` (`id`, `member_id`, `change_count`, `data_source`, `remark`, `create_time`, `create_by`, `update_time`, `update_by`, `is_deleted`, `version`) VALUES (1685217056088387586, 1, 10, '1', '每日签到', '2023-07-29 17:13:51', 'Leron', NULL, NULL, b'0', 1);
INSERT INTO `ums_growth_change_history` (`id`, `member_id`, `change_count`, `data_source`, `remark`, `create_time`, `create_by`, `update_time`, `update_by`, `is_deleted`, `version`) VALUES (1686388287919579137, 1, 10, '1', '每日签到', '2023-08-01 22:47:54', 'Leron', NULL, NULL, b'0', 1);
INSERT INTO `ums_growth_change_history` (`id`, `member_id`, `change_count`, `data_source`, `remark`, `create_time`, `create_by`, `update_time`, `update_by`, `is_deleted`, `version`) VALUES (1686774054983929857, 1, 10, '1', '每日签到', '2023-08-03 00:20:48', 'Leron', NULL, NULL, b'0', 1);
COMMIT;

-- ----------------------------
-- Table structure for ums_integration_change_history
-- ----------------------------
DROP TABLE IF EXISTS `ums_integration_change_history`;
CREATE TABLE `ums_integration_change_history` (
  `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'id',
  `member_id` bigint DEFAULT NULL COMMENT 'member_id',
  `change_count` int NOT NULL COMMENT '变更数值',
  `data_source` tinyint NOT NULL COMMENT '数据来源',
  `remark` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci DEFAULT NULL,
  `create_time` datetime DEFAULT NULL,
  `create_by` varchar(255) DEFAULT NULL,
  `update_time` datetime DEFAULT NULL,
  `update_by` varchar(255) DEFAULT NULL,
  `is_deleted` bit(1) NOT NULL DEFAULT b'0',
  `version` int NOT NULL DEFAULT '1',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1686774055101370370 DEFAULT CHARSET=utf8mb3 ROW_FORMAT=DYNAMIC COMMENT='会员积分变更记录';

-- ----------------------------
-- Records of ums_integration_change_history
-- ----------------------------
BEGIN;
INSERT INTO `ums_integration_change_history` (`id`, `member_id`, `change_count`, `data_source`, `remark`, `create_time`, `create_by`, `update_time`, `update_by`, `is_deleted`, `version`) VALUES (1683848569633894402, 1, 10, 1, '每日签到', '2023-07-25 22:35:58', 'Leron', NULL, NULL, b'0', 1);
INSERT INTO `ums_integration_change_history` (`id`, `member_id`, `change_count`, `data_source`, `remark`, `create_time`, `create_by`, `update_time`, `update_by`, `is_deleted`, `version`) VALUES (1685217056872722433, 1, 10, 1, '每日签到', '2023-07-29 17:13:51', 'Leron', NULL, NULL, b'0', 1);
INSERT INTO `ums_integration_change_history` (`id`, `member_id`, `change_count`, `data_source`, `remark`, `create_time`, `create_by`, `update_time`, `update_by`, `is_deleted`, `version`) VALUES (1686388288141877250, 1, 10, 1, '每日签到', '2023-08-01 22:47:54', 'Leron', NULL, NULL, b'0', 1);
INSERT INTO `ums_integration_change_history` (`id`, `member_id`, `change_count`, `data_source`, `remark`, `create_time`, `create_by`, `update_time`, `update_by`, `is_deleted`, `version`) VALUES (1686774055101370369, 1, 10, 1, '每日签到', '2023-08-03 00:20:48', 'Leron', NULL, NULL, b'0', 1);
COMMIT;

-- ----------------------------
-- Table structure for ums_member
-- ----------------------------
DROP TABLE IF EXISTS `ums_member`;
CREATE TABLE `ums_member` (
  `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'id',
  `username` varchar(100) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci DEFAULT NULL COMMENT '账户',
  `password` varchar(64) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci DEFAULT NULL,
  `integral` int NOT NULL DEFAULT '0' COMMENT '积分',
  `mobile` varchar(20) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci DEFAULT NULL COMMENT '手机',
  `growth` int NOT NULL DEFAULT '1' COMMENT '成长值',
  `avatar` varchar(500) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci DEFAULT NULL COMMENT '头像',
  `status` tinyint(1) NOT NULL DEFAULT '1' COMMENT '状态',
  `create_time` datetime DEFAULT NULL,
  `create_by` varchar(255) DEFAULT NULL,
  `update_time` datetime DEFAULT NULL,
  `update_by` varchar(255) DEFAULT NULL,
  `is_deleted` bit(1) NOT NULL DEFAULT b'0',
  `version` int NOT NULL DEFAULT '1',
  PRIMARY KEY (`id`) USING BTREE,
  UNIQUE KEY `username_idx` (`username`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci ROW_FORMAT=DYNAMIC;

-- ----------------------------
-- Records of ums_member
-- ----------------------------
BEGIN;
INSERT INTO `ums_member` (`id`, `username`, `password`, `integral`, `mobile`, `growth`, `avatar`, `status`, `create_time`, `create_by`, `update_time`, `update_by`, `is_deleted`, `version`) VALUES (1, 'Leron', '$2a$10$.3F2pDTajyV4KTg0eMBy6.aVQ3Xv/0MPR/Fw44EjD.lM7wU8lP5sy', 900, '15615001223', 90, 'https://leron-public.oss-cn-qingdao.aliyuncs.com/xymall/avatar.jpeg', 2, NULL, NULL, '2023-08-03 00:20:48', 'Leron', b'0', 8);
COMMIT;

-- ----------------------------
-- Table structure for ums_member_level
-- ----------------------------
DROP TABLE IF EXISTS `ums_member_level`;
CREATE TABLE `ums_member_level` (
  `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'id',
  `name` varchar(100) DEFAULT NULL,
  `growth_point` int DEFAULT NULL,
  `default_status` tinyint DEFAULT NULL,
  `free_freight_point` decimal(18,4) DEFAULT NULL,
  `comment_growth_point` int DEFAULT NULL COMMENT 'ÿ',
  `priviledge_free_freight` tinyint DEFAULT NULL,
  `priviledge_member_price` tinyint DEFAULT NULL,
  `priviledge_birthday` tinyint DEFAULT NULL,
  `note` varchar(255) DEFAULT NULL,
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb3 ROW_FORMAT=DYNAMIC;

-- ----------------------------
-- Records of ums_member_level
-- ----------------------------
BEGIN;
INSERT INTO `ums_member_level` (`id`, `name`, `growth_point`, `default_status`, `free_freight_point`, `comment_growth_point`, `priviledge_free_freight`, `priviledge_member_price`, `priviledge_birthday`, `note`) VALUES (2, '初级会员', 0, 1, 1000.0000, 10, 0, 0, 0, '初始会员');
INSERT INTO `ums_member_level` (`id`, `name`, `growth_point`, `default_status`, `free_freight_point`, `comment_growth_point`, `priviledge_free_freight`, `priviledge_member_price`, `priviledge_birthday`, `note`) VALUES (3, '银牌会员', 1000, 0, 800.0000, 8, 1, 1, 1, '银牌');
INSERT INTO `ums_member_level` (`id`, `name`, `growth_point`, `default_status`, `free_freight_point`, `comment_growth_point`, `priviledge_free_freight`, `priviledge_member_price`, `priviledge_birthday`, `note`) VALUES (4, '金牌会员', 2000, 0, 500.0000, 5, 1, 1, 1, '金牌会员');
INSERT INTO `ums_member_level` (`id`, `name`, `growth_point`, `default_status`, `free_freight_point`, `comment_growth_point`, `priviledge_free_freight`, `priviledge_member_price`, `priviledge_birthday`, `note`) VALUES (5, '超级会员', 5000, 0, 0.0000, 0, 1, 1, 1, '最高会员');
COMMIT;

-- ----------------------------
-- Table structure for ums_member_receive_address
-- ----------------------------
DROP TABLE IF EXISTS `ums_member_receive_address`;
CREATE TABLE `ums_member_receive_address` (
  `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'id',
  `member_id` bigint NOT NULL COMMENT 'member_id',
  `name` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL COMMENT '收货人姓名',
  `phone` varchar(64) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL COMMENT '联系电话',
  `post_code` varchar(64) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci DEFAULT NULL COMMENT '邮编',
  `province` varchar(100) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL COMMENT '省份',
  `city` varchar(100) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL COMMENT '城市',
  `region` varchar(100) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL COMMENT '区域',
  `detail_address` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL COMMENT '详细地址',
  `is_default` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否默认',
  `create_time` datetime DEFAULT NULL,
  `create_by` varchar(255) DEFAULT NULL,
  `update_time` datetime DEFAULT NULL,
  `update_by` varchar(255) DEFAULT NULL,
  `is_deleted` bit(1) NOT NULL DEFAULT b'0',
  `version` int NOT NULL DEFAULT '0',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1685652035523989507 DEFAULT CHARSET=utf8mb3 ROW_FORMAT=DYNAMIC;

-- ----------------------------
-- Records of ums_member_receive_address
-- ----------------------------
BEGIN;
INSERT INTO `ums_member_receive_address` (`id`, `member_id`, `name`, `phone`, `post_code`, `province`, `city`, `region`, `detail_address`, `is_default`, `create_time`, `create_by`, `update_time`, `update_by`, `is_deleted`, `version`) VALUES (1, 1, '利若', '15615001223', '000000', '山东省', '菏泽市', '成武县', '金枫南路蓝光和雍锦园', 1, NULL, NULL, '2023-07-29 16:56:20', 'Leron', b'0', 0);
INSERT INTO `ums_member_receive_address` (`id`, `member_id`, `name`, `phone`, `post_code`, `province`, `city`, `region`, `detail_address`, `is_default`, `create_time`, `create_by`, `update_time`, `update_by`, `is_deleted`, `version`) VALUES (1685212615096393730, 1, '刘贤', '15615001223', NULL, '北京市', '市辖区', '西城区', '讲究', 0, '2023-07-29 16:56:12', 'Leron', NULL, NULL, b'1', 0);
INSERT INTO `ums_member_receive_address` (`id`, `member_id`, `name`, `phone`, `post_code`, `province`, `city`, `region`, `detail_address`, `is_default`, `create_time`, `create_by`, `update_time`, `update_by`, `is_deleted`, `version`) VALUES (1685651568085585922, 1, '刘贤', '15615001223', NULL, '北京市', '市辖区', '西城区', '玫瑰花园', 0, '2023-07-30 22:00:26', 'Leron', NULL, NULL, b'0', 0);
INSERT INTO `ums_member_receive_address` (`id`, `member_id`, `name`, `phone`, `post_code`, `province`, `city`, `region`, `detail_address`, `is_default`, `create_time`, `create_by`, `update_time`, `update_by`, `is_deleted`, `version`) VALUES (1685652035523989506, 1, '张三', '15615001223', NULL, '北京市', '市辖区', '石景山区', '玫瑰花园', 0, '2023-07-30 22:02:18', 'Leron', NULL, NULL, b'0', 0);
COMMIT;

-- ----------------------------
-- Table structure for undo_log
-- ----------------------------
DROP TABLE IF EXISTS `undo_log`;
CREATE TABLE `undo_log` (
  `id` bigint NOT NULL AUTO_INCREMENT,
  `branch_id` bigint NOT NULL,
  `xid` varchar(100) NOT NULL,
  `context` varchar(128) NOT NULL,
  `rollback_info` longblob NOT NULL,
  `log_status` int NOT NULL,
  `log_created` datetime NOT NULL,
  `log_modified` datetime NOT NULL,
  `ext` varchar(100) DEFAULT NULL,
  PRIMARY KEY (`id`) USING BTREE,
  UNIQUE KEY `ux_undo_log` (`xid`,`branch_id`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 ROW_FORMAT=DYNAMIC;

-- ----------------------------
-- Records of undo_log
-- ----------------------------
BEGIN;
COMMIT;

SET FOREIGN_KEY_CHECKS = 1;
